var arr1=['A','B'];
var arr2=['C'];
var arr3=['D'];

var concatedArr=arr1.concat(arr2,arr3);

console.log(concatedArr);

console.log("---test forEach--");

concatedArr.forEach(function(info,index){
    if(index===2)
        return;

    console.log(info,index);
});

console.log("---test map--");

var newConcatedArr=concatedArr.map(function(info,index){
    if(index===2)
        return;
    return info+"_"+index;
});

console.log(newConcatedArr);

console.log("-------");

//返回数组下标
var fruits=['apple','mango','banana','orange'];
var index=fruits.indexOf('banana');

console.log(index);

concatedArr.pop();
concatedArr.shift();
console.log('----------------------')
concatedArr.forEach(function(info,index){
    console.log(info,index);
});


